This example defines several routines for patching the ADB manager to simulate the control key being held down. This file contains declarations for routines in ControlKeyPatch.c. These routines are for installing, removing and calling the control key patch.
This sample works by patching the ADB service routine for the keyboard. It then allows you to call the service routine to simulate the control key. Also, the while it is simulating the control key being held down, it filters out 'actual' control key events sent from the keyboard.
You may incorporate this sample code into your applications without restriction, though the sample code has been provided "AS IS" and the responsibility for its operation is 100% yours. However, what you are not permitted to do is to redistribute the source as "DSC Sample Code" after having made changes. If you're going to re-distribute the source, we require that you make it clear in the source that the code was descended from Apple Sample Code, but that you've made changes.
Change History (most recent first):
27/8/99 created by John Montbriand
Files:
':ControlKeyTest.prj Data:' - CodeWarrior project data is stored in this folder.
:obj: - object files created during builds are stored in this folder.
ControlKeyPatch.a - assembler source for the patch resource.
ControlKeyPatch.a.c - same as ControlKeyPatch.a but formatted for use with CodeWarrior.
ControlKeyPatch.c - routines for installing/removing/calling the patch resource.
ControlKeyPatch.h - declarations for routines in ControlKeyPatch.c.
ControlKeyTest - A test application illustrating how to use the patch.
ControlKeyTest.c - C source for the test application.
ControlKeyTest.prj - CodeWarrior project file to build the test application.
ControlKeyTest.r - MPW Rez file for some of the test application's resources.
ControlKeyTest.rsrc - ResEdit resource file for some of the test application's resources.
MakeFile - MPW make file that builds the test application.